package org.saasplay.core;

import org.saasplay.resource.FeedBack;
import org.saasplay.resource.ResourceData;
import org.saasplay.resource.Tickets;

/**
 * @author cuishifeng
 */
public abstract class ResourceFilter implements ServiceHandler {

    /**
     * 过滤掉服务资源
     *
     * @param tickets
     * @param resourceData
     * @return
     * @throws Exception
     */
    public abstract FeedBack filterOutResource(Tickets tickets, ResourceData resourceData) throws Exception;


    @Override
    public FeedBack getFeedBack(Tickets tickets, ResourceData resource) throws Exception {
        return filterOutResource(tickets, resource);
    }
}
